A compiler is a computer program that takes as input a computer program written a source language and produces as output an equivalent computer program written in a target language. It may be designed to translate any source language into any target language. Many compilers, however, are designed to accept only one source and one target language. The source and target languages of these compilers are selected when the compiler is first written. Changing them is nearly impossible and would require a rewrite of virtually the entire compiler.
Recent trends in the computer industry have been towards more complicated computer programs, often written in multiple computer languages. Furthermore, multiple computer languages might appear in a single source file, often with one language nested inside another. Traditional multiple language compilers are not sufficient to deal with this problem. Some of them were designed to deal with multiple languages in a single source file in limited examples, but none of them deal with the problem in a general way. Furthermore, such compilers cannot be easily extended to support new languages or new combinations of languages in a source file.
The demands on compilers are increasing in other ways as well. In the past a compiler was designed to serve a single client, typically command line interface, to perform batch compilation of a group of files. Modern compilers are facing more diverse clients which require far more detailed information from compiler. These clients include the traditional batch mode user interfaces as well as integrated development environments.